using System;
using System.Collections.Generic;
using System.Text;
using TaugeLibrary.Enums;

namespace TaugeLibrary.Classes.Attributes
{
    [AttributeUsage(AttributeTargets.Class , AllowMultiple = false)]
    public class AttBindUI:System.Attribute
    {
        string m_ui;
        public string UI { get { return m_ui; } set { m_ui = value; } }

        public AttBindUI(string p_ui)
        {
            UI = p_ui;
        }
    }

    [AttributeUsage(AttributeTargets.Property, AllowMultiple = false)]
    public class AttBindControl : System.Attribute
    {
        eControlType m_control_type;
        public eControlType ControlType { set { m_control_type = value; } get { return m_control_type; } }

        string m_control_name;
        public string ControlName { get { return m_control_name; } set { m_control_name = value; } }

        bool m_write_only=false;
        public bool WriteOnly { get { return m_write_only; } set { m_write_only = true; } }

        bool m_bind_parent_form = false;
        public bool BindParentForm { get { return m_bind_parent_form; } set { m_bind_parent_form = value; } }

        public AttBindControl(eControlType p_control_type, string p_control_name)
        {
            ControlType = p_control_type;
            ControlName = p_control_name;
        }
                

    }
}
